import React, { Component, Fragment } from 'react';
import { Link } from 'react-router-dom';
import { renderRoutes } from 'react-router-config';
import { LogoHeader } from 'components/Header';
import styles from './index.module.less';

export default class ContentPages extends Component {
  render() {
    const rightContent = (
      <div className={styles.menuBox}>
        <Link className={styles.menuItem} to='/'>首页</Link>
        <Link className={styles.menuItem} to=''>买家中心</Link>
        <Link className={styles.menuItem} to=''>卖家中心</Link>
      </div>
    );
    return <Fragment>
      <LogoHeader moduleName="欢迎登陆" rightContent={rightContent} />
      <Fragment>
        {renderRoutes(this.props.route.routes)}
      </Fragment>
    </Fragment>;
  }
}
